<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">

<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    <script th:src="@{/layui/layui.js}"></script>
    <link rel="stylesheet" th:href="@{/layui/css/layui.css}" media="all">
    <script th:src="@{/layui/layui.all.js}"></script>
</head>
<body>
<form method="post" th:action="@{/sys/password(id=${admin.getId()})}">
    <div class="layui-fluid">
        <div class="layui-row layui-col-space15">
            <div class="layui-col-md12">
                <div class="layui-card">
                    <div class="layui-card-header">
                        修改密码 &nbsp;&nbsp;<span style="color:green;" th:text="${success}" th:if="${not #strings.isEmpty(success)}"></span>
                    </div>
                    <div class="layui-card-body" >
                        <div class="layui-form" >
                            <div class="layui-form-item">
                                <label class="layui-form-label">当前密码</label>
                                <div class="layui-input-inline">
                                    <input type="password" name="oldPassword" class="layui-input">
                                </div>
                                <div class="layui-form-mid layui-word-aux"><p style="color:red;" th:text="${errorold}" th:if="${not #strings.isEmpty(errorold)}"></p></div>
                            </div>
                            <div class="layui-form-item">
                                <label class="layui-form-label">新密码</label>
                                <div class="layui-input-inline">
                                    <input type="password" name="newPassword"  autocomplete="off"  class="layui-input">
                                </div>
                            </div>
                            <div class="layui-form-item">
                                <label class="layui-form-label">确认新密码</label>
                                <div class="layui-input-inline">
                                    <input type="password" name="confirmPassword" autocomplete="off" class="layui-input">
                                </div>
                                <div class="layui-form-mid layui-word-aux"><p style="color:red;" th:text="${errornewpwd}" th:if="${not #strings.isEmpty(errornewpwd)}"></p></div>
                            </div>
                            <div class="layui-form-item">
                                <div class="layui-input-block">
                                    <button class="layui-btn" >确认修改</button>
                                </div>
                            </div>
                        </div>

                    </div>
                </div>
            </div>
        </div>
    </div>

</form>
<script src="${pageContext.request.contextPath}/static/layui/layui.js"></script>
<script src="${pageContext.request.contextPath}/static/layui/layui.all.js"></script>
</body>
</html>